function pls=genpls(w,dt)
    pls=zeros(gsize,3*gsize-1);
    for i=0:dt:3*gsize-2
        //plo=rpls2();
        plo=zeros(gsize,H);
        plsi=plsir2(plo,w,i);
        pls(:,i+1:i+dt)=plsi(:,1:dt);
    end
endfunction
function pls=genpls2(w,dt)
    pls=zeros(gsize,3*gsize-1);
    for i=0:dt:3*gsize-2
        //plo=rpls2();
        //plo=zeros(gsize,H);
        plsi=vlir2(w,i);
        pls(:,i+1:i+dt)=plsi(:,1:dt);
    end
endfunction
